SQL Object

The sql object can be used to format field values according to the current database format.

Expression Description
${sql.currentDate} Formats current date
${sql.currentTime} Formats current time
${sql.currentTimestamp} Formats current timestamp
${sql.date(value)} Formats date literal
${sql.time(value)} Formats time literal
${sql.timestamp(value)} Formats timestamp literal
${sql.timestamp(dateField, timeField)} Formats timestamp SQL expression that concatenates two fields: date and time
value1${sql.concat}value2 Formats SQL expression that concatenates two values
${sql.as} Inserts the AS keyword if it is supported/required by the database
${sql.yearOf(column)}

Formats SQL expression that returns the year of a value contained in specified column

${sql.yearQuarterOf(column)} Formats SQL expression that returns the year-quarter of a value contained in specified column
${sql.yearWeekOf(column)} Formats SQL expression that returns the year-week of a value contained in specified column
${sql.yearMonthOf(column)} Formats SQL expression that returns the year-month of a value contained in specified column
${sql.yearMonthDayOf(column)} Formats SQL expression that returns the year-month-day of a value contained in specified column